package cn.wokoba.dao.dao;

import cn.wokoba.dao.dao.po.GroupBuyDiscount;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;


@Mapper
public interface IGroupBuyDiscountDao extends BaseMapper<GroupBuyDiscount> {

    @Select(" select * from group_buy_discount")
    List<GroupBuyDiscount> queryGroupBuyDiscountList();

    @Select("""
                    select discount_id, discount_name, discount_desc, discount_type, market_plan, market_expr, tag_id
                    from group_buy_discount
                    where discount_id = #{discountId}\
            """)
    GroupBuyDiscount queryGroupBuyActivityDiscountByDiscountId(String discountId);

}
